package cn.leaf.uc.service.controller;

import cn.leaf.uc.service.service.UserService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RequestMapping(value = "user")
@RestController
public class UserController {

    @Resource
    private UserService userService;

    @GetMapping(value = "register")
    public String register() {
        int result = userService.register();
        if (result > 0) {
            return "成功";
        }
        return "失败";
    }

}
